<html>
<head><meta charset="utf-8"><title>weekly meeting-ish 2019.04.02 · wg-async-foundations · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/index.html">wg-async-foundations</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html">weekly meeting-ish 2019.04.02</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="162353504"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162353504" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162353504">(Apr 02 2019 at 17:00)</a>:</h4>
<p><span class="user-group-mention" data-user-group-id="1172">@WG-async-await</span> o/</p>



<a name="162353629"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162353629" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162353629">(Apr 02 2019 at 17:01)</a>:</h4>
<p>Status updates:<br>
- <a href="https://github.com/rust-lang/rust/pull/59286" target="_blank" title="https://github.com/rust-lang/rust/pull/59286">https://github.com/rust-lang/rust/pull/59286</a> has landed, fixes all known <code>async fn</code> lifetime bugs, but multiple lifetimes are still unsupported</p>



<a name="162353722"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162353722" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162353722">(Apr 02 2019 at 17:02)</a>:</h4>
<p><span class="user-mention" data-user-id="116107">@davidtwco</span> I saw you closed <a href="https://github.com/rust-lang/rust/pull/59135" target="_blank" title="https://github.com/rust-lang/rust/pull/59135">https://github.com/rust-lang/rust/pull/59135</a></p>



<a name="162353823"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162353823" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162353823">(Apr 02 2019 at 17:03)</a>:</h4>
<p>I've nominated <a href="https://github.com/rust-lang/rust/issues/54716" target="_blank" title="https://github.com/rust-lang/rust/issues/54716">https://github.com/rust-lang/rust/issues/54716</a> for discussion in the next lang mtg so we can figure out what we want.</p>



<a name="162353905"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162353905" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162353905">(Apr 02 2019 at 17:04)</a>:</h4>
<p><span class="user-mention" data-user-id="116107">@davidtwco</span> is <a href="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/.2354716.20drop.20order/near/160792119" title="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/.2354716.20drop.20order/near/160792119">https://rust-lang.zulipchat.com/#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/.2354716.20drop.20order/near/160792119</a> still the most up-to-date summary?</p>



<a name="162353924"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162353924" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> davidtwco <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162353924">(Apr 02 2019 at 17:04)</a>:</h4>
<blockquote>
<p><span class="user-mention silent" data-user-id="116107">davidtwco</span> I saw you closed <a href="https://github.com/rust-lang/rust/pull/59135" target="_blank" title="https://github.com/rust-lang/rust/pull/59135">https://github.com/rust-lang/rust/pull/59135</a></p>
</blockquote>
<p>I wasn't able to resolve the type inference issues that the PR had, and wasn't super happy with the approach it took - particularly the way it mangled the HIR into shape.</p>
<blockquote>
<p>I've nominated <a href="https://github.com/rust-lang/rust/issues/54716" target="_blank" title="https://github.com/rust-lang/rust/issues/54716">https://github.com/rust-lang/rust/issues/54716</a> for discussion in the next lang mtg so we can figure out what we want.</p>
</blockquote>
<p>Sounds good. </p>
<blockquote>
<p><span class="user-mention silent" data-user-id="116107">davidtwco</span> is <a href="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/.2354716.20drop.20order/near/160792119" title="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/.2354716.20drop.20order/near/160792119">https://rust-lang.zulipchat.com/#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/.2354716.20drop.20order/near/160792119</a> still the most up-to-date summary?</p>
</blockquote>
<p>Yes.</p>



<a name="162354110"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354110" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354110">(Apr 02 2019 at 17:06)</a>:</h4>
<p>One thing I was thinking about that sort of bothered me was how quickly we decided to accept that the current behavior wasn't the one we wanted-- namely, the current behavior actually has some advantages in terms of how unused variables aren't captured as part of the upvars of the generator, which helps with size, and dropping them early could potentially be a performance help.</p>



<a name="162354120"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354120" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> davidtwco <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354120">(Apr 02 2019 at 17:06)</a>:</h4>
<p>Behaviour-wise, I think the PR achieved the desired effect (<a href="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/.2354716.20drop.20order/near/161168300" title="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/.2354716.20drop.20order/near/161168300">not quite the exact same ordering though</a>). The only issues I had were with the implementation.</p>



<a name="162354187"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354187" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354187">(Apr 02 2019 at 17:07)</a>:</h4>
<p>yeah, it's definitely closer to what we discussed. I'm just having thoughts :)</p>



<a name="162354251"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354251" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> davidtwco <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354251">(Apr 02 2019 at 17:08)</a>:</h4>
<p>There are certainly benefits to the way it works just now.</p>



<a name="162354271"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354271" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354271">(Apr 02 2019 at 17:08)</a>:</h4>
<p><span class="user-mention" data-user-id="116883">@tmandry</span> has been making more progress on <a href="https://github.com/rust-lang/rust/issues/52924" target="_blank" title="https://github.com/rust-lang/rust/issues/52924">https://github.com/rust-lang/rust/issues/52924</a></p>



<a name="162354312"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354312" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354312">(Apr 02 2019 at 17:09)</a>:</h4>
<p><a href="https://github.com/rust-lang/rust/pull/59514" target="_blank" title="https://github.com/rust-lang/rust/pull/59514">https://github.com/rust-lang/rust/pull/59514</a> is part of that work</p>



<a name="162354329"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354329" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> davidtwco <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354329">(Apr 02 2019 at 17:09)</a>:</h4>
<p>Though, the arguments you've put forward there are mostly relating to performance rather than the user's expectations. We can put patches in place to improve the performance but if the behaviour isn't what the user expects, we can't patch that later.</p>



<a name="162354335"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354335" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354335">(Apr 02 2019 at 17:09)</a>:</h4>
<p><span class="user-mention" data-user-id="116883">@tmandry</span> looks like it's good to go w/ one final comment</p>



<a name="162354351"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354351" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354351">(Apr 02 2019 at 17:09)</a>:</h4>
<p><span class="user-mention" data-user-id="116107">@davidtwco</span> yup, but we also can't introduce optimizations that break observable behavior</p>



<a name="162354416"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354416" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> davidtwco <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354416">(Apr 02 2019 at 17:10)</a>:</h4>
<p>I don't have an opinion either way.</p>



<a name="162354425"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354425" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354425">(Apr 02 2019 at 17:10)</a>:</h4>
<p>so the only way to get those performance improvements would be through specifying the observable behavior to be something other than the naiive expectation</p>



<a name="162354440"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354440" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354440">(Apr 02 2019 at 17:10)</a>:</h4>
<p>Yeah, I think it's a good topic to discuss in the t-lang mtg</p>



<a name="162354651"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354651" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354651">(Apr 02 2019 at 17:13)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> and I were supposed to figure out what to do about region inference for existential types, but I wasn't successful in sorting this out before I went on PTO last week, and he's out this week. This blocks multiple lifetimes in <code>async fn</code>.</p>



<a name="162354773"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354773" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354773">(Apr 02 2019 at 17:14)</a>:</h4>
<p>Aside from those (drop order, generator size, multiple lifetimes), I believe the remaining blockers are all tightly related to native syntax</p>



<a name="162354783"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354783" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354783">(Apr 02 2019 at 17:14)</a>:</h4>
<p>which is a t-lang bit to resolve.</p>



<a name="162354872"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354872" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354872">(Apr 02 2019 at 17:15)</a>:</h4>
<p>I think, unless <span class="user-mention" data-user-id="116883">@tmandry</span> has anything to discuss, that's all we have at the moment.</p>



<a name="162354936"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354936" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354936">(Apr 02 2019 at 17:16)</a>:</h4>
<p>One bit I'd like to adjust is the order btw <code>async</code> and <code>unsafe</code></p>



<a name="162354948"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354948" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354948">(Apr 02 2019 at 17:16)</a>:</h4>
<p>currently <code>unsafe</code> comes first</p>



<a name="162354955"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354955" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354955">(Apr 02 2019 at 17:16)</a>:</h4>
<p><span class="user-mention" data-user-id="126931">@centril</span> sure-- can you open an issue and nominate it for t-lang?</p>



<a name="162354959"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162354959" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162354959">(Apr 02 2019 at 17:16)</a>:</h4>
<p><span aria-label="+1" class="emoji emoji-1f44d" role="img" title="+1">:+1:</span></p>



<a name="162355013"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355013" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355013">(Apr 02 2019 at 17:17)</a>:</h4>
<p>(my expectation would be unsafe first as well, but I don't care deeply-- honestly I think it's a bit confusing that we have so many modifiers and they all have to be in a specific order in order for the parser not to tell you garbage)</p>



<a name="162355032"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355032" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355032">(Apr 02 2019 at 17:17)</a>:</h4>
<p>Nothing to discuss, really. I think we're going to end up doing <a href="https://github.com/rust-lang/rust/issues/52924" target="_blank" title="https://github.com/rust-lang/rust/issues/52924">#52924</a> the "right" way from the start in terms of layout and debuginfo, though maybe not with all enum optimizations enabled from day one</p>



<a name="162355037"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355037" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355037">(Apr 02 2019 at 17:17)</a>:</h4>
<p>I guess the "parser tells you garbage" is more of a diagnostics bug than a design issue, though</p>



<a name="162355140"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355140" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355140">(Apr 02 2019 at 17:18)</a>:</h4>
<p><span class="user-mention" data-user-id="116883">@tmandry</span> can you say what you mena about the "right" way? you mean without the "only if the places are only valid for one <code>yield</code> point" trick?</p>



<a name="162355163"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355163" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355163">(Apr 02 2019 at 17:18)</a>:</h4>
<p>No, it'll still just have that optimization</p>



<a name="162355202"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355202" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355202">(Apr 02 2019 at 17:19)</a>:</h4>
<p>I mean more in terms of how generators integrate with the rest of the compiler backend, and what kinds of optimizations we can enable</p>



<a name="162355249"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355249" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355249">(Apr 02 2019 at 17:19)</a>:</h4>
<p>I think the expectation is "it can act just like an enum" with all the optimizations that come with that, and we're doing the refactoring work to let us meet those expectations, eventually</p>



<a name="162355367"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355367" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355367">(Apr 02 2019 at 17:21)</a>:</h4>
<p>The code and layout that comes out should look exactly as if you hand-rolled an enum</p>



<a name="162355414"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355414" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355414">(Apr 02 2019 at 17:21)</a>:</h4>
<p>But this required some refactoring, e.g. next up is changing the field number of the discriminant, and removing the assumption that multi-variant layouts only have one field (for the discriminant) on their outer layout</p>



<a name="162355426"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355426" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355426">(Apr 02 2019 at 17:21)</a>:</h4>
<p>So we can have an "enum" (multi-variant layout) with fields that are always-valid, regardless of the value of the discriminant</p>



<a name="162355500"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355500" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355500">(Apr 02 2019 at 17:22)</a>:</h4>
<p>This should allow us to do all the UB checking that <span class="user-mention" data-user-id="120791">@RalfJ</span> was talking about too (<a href="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/shrinking.20generators.20.2352924/near/160079659" title="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/shrinking.20generators.20.2352924/near/160079659">link</a>)</p>



<a name="162355510"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355510" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355510">(Apr 02 2019 at 17:22)</a>:</h4>
<p>Rather than just treating generators as blobs of bytes</p>



<a name="162355573"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355573" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355573">(Apr 02 2019 at 17:23)</a>:</h4>
<p>Does that make sense?</p>



<a name="162355860"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355860" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355860">(Apr 02 2019 at 17:28)</a>:</h4>
<p>Yeah! that sounds much better than what I'd been imagining :)</p>



<a name="162355981"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162355981" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162355981">(Apr 02 2019 at 17:29)</a>:</h4>
<p><span class="user-mention" data-user-id="116883">@tmandry</span> does this also mean that we wouldn't have the single i32 (or whatever it was) tag field anymore, but do niche-filling for the tag as well?</p>



<a name="162356007"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162356007" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162356007">(Apr 02 2019 at 17:29)</a>:</h4>
<p>I think that should be pretty straightforward to enable</p>



<a name="162356018"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162356018" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162356018">(Apr 02 2019 at 17:29)</a>:</h4>
<p>But not making any promises ;)</p>



<a name="162356100"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/187312-wg-async-foundations/topic/weekly%20meeting-ish%202019.04.02/near/162356100" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/187312-wg-async-foundations/topic/weekly.20meeting-ish.202019.2E04.2E02.html#162356100">(Apr 02 2019 at 17:30)</a>:</h4>
<p>Cool, good to know.</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>